<%= form_tag search_path, method: :get, class: 'navbar-form search_form', enforce_utf8: false do |f| %>
  <div class="input-group input-group">
    <%= text_field_tag 'q', "#{@query || '' }", placeholder: 'Search Packages', class: 'form-control search-input', size: 40 %>
    <% [:platforms, :licenses, :languages, :keywords, :sort].each do |field| %>
      <%= hidden_field_tag field, params[field] if params[field].present? %>
    <% end %>
    <span class="input-group-btn">
      <button class="btn btn-primary" type="submit">
        <%= fa_icon 'search' %>
      </button>
    </span>
  </div>
<% end %>
